﻿<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2" default-access="property" default-lazy="true" namespace="Cms.Domain" assembly="Cms.Domain">
  <class name="MenuVersion" table="cmsMenuVersion">
    <cache usage="read-write" />
    <id name="ID" type="System.Int32" unsaved-value="0">
      <column name="ID" />
      <generator class="identity" />
    </id>
    <property name="Timestamp" type="System.String">
      <column name="Timestamp" not-null="true" />
    </property>
    <bag cascade="all-delete-orphan" inverse="true" name="Items" table="cmsMenuItem" mutable="true" order-by="SortIndex">
      <cache usage="read-write" />
      <key>
        <column name="MenuVersionID" />
      </key>
      <one-to-many class="MenuItem" />
    </bag>
    <many-to-one class="Menu" name="Parent">
      <column name="MenuID" not-null="true" />
    </many-to-one>
    <many-to-one class="Administrator" name="EditedBy">
      <column name="EditedByAdministratorID" not-null="true" />
    </many-to-one>
  </class>
</hibernate-mapping>